/**
 * Created by Administrator on 2017/7/12.
 */

import React,{
    Component,
    PropTypes
} from 'react';

import {
    Text
} from 'react-native';


export default class PropsTest extends Component{

    static defaultProps = {
        name:'无名氏',
        sex:'未知',
        age:0
    }

    static propTyps = {
        name:PropTypes.string.isRequired,
        sex:PropTypes.string.isRequired,
        age:PropTypes.number.isRequired
    }

    render(){
        return <Text>姓名:{this.props.name} 性别:{this.props.sex} 年龄 :{this.props.age}</Text>
    }


}